<?php if (!defined('THINK_PATH')) exit(); /*a:3:{s:35:"./template/default/pc/map\index.htm";i:1585028316;s:68:"D:\phpstudy\PHPTutorial\WWW\ejs86\template\default\pc\map\header.htm";i:1585028316;s:65:"D:\phpstudy\PHPTutorial\WWW\ejs86\template\default\pc\map\nav.htm";i:1585028316;}*/ ?>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title><?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_title"); echo $__VALUE__; ?>_地图找房</title>
<meta name="keywords" content="地图找房" />
<meta name="description" content="" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
<link href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_cmspath"); echo $__VALUE__; ?>/favicon.ico" rel="shortcut icon" type="image/x-icon" />
<?php  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("skin/css/eju.css","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/css/public.css","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/css/ditu.css","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/css/map.css","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/css/reset.css","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/css/common.css","",""); echo $__VALUE__; ?>
<link rel="stylesheet" type="text/css" href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_templets_pc"); echo $__VALUE__; ?>/skin/css/common.css">
<link rel="stylesheet" type="text/css" href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_templets_pc"); echo $__VALUE__; ?>/skin/css/css.css">
<script src="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_templets_pc"); echo $__VALUE__; ?>/skin/js/jquery.min.js"></script>
</head><body>
<!-- topBar S --> 
<div class="index-header-style" style="position: relative;">
  <div class="index-header-wrap clearfix">
    <div class="index-header-bd">
      <h1 id="index-header-logo" title="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_title"); echo $__VALUE__; ?>"> <a href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_cmsurl"); echo $__VALUE__; ?>" class="clickstat"> <img class="hy-hd-logo-0" src="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_logo"); echo $__VALUE__; ?>" alt="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_title"); echo $__VALUE__; ?>"/></a> </h1>
      <div class="index-city-choose"> <a href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_cmsurl"); echo $__VALUE__; ?>" class="city-loc"> </a> </div>
      <div class="index-header-nav"> <?php  $navigid = ""; if(empty($navigid) && isset($navigartlist["navig_id"]) && !empty($navigartlist["navig_id"])) : $navigid = intval($navigartlist["navig_id"]); endif;  $row = 100; $tagNavig = new \think\template\taglib\eju\TagNavig; $_result = $tagNavig->getNavig("1", $navigid, "top", "active", ""); if(is_array($_result) || $_result instanceof \think\Collection || $_result instanceof \think\Paginator): $i = 0; $e = 1;$k=0;$__LIST__ = is_array($_result) ? array_slice($_result,0, $row, true) : $_result->slice(0, $row, true); if( count($__LIST__)==0 ) : echo htmlspecialchars_decode("");else: foreach($__LIST__ as $key=>$field): $field["navig_name"] = text_msubstr($field["navig_name"], 0, 100, false); $__LIST__[$key] = $_result[$key] = $field;$i= intval($key) + 1;$mod = ($i % 2 ); ?>
        <div  class="hy-nav-item <?php echo $field['currentstyle']; ?>"><a href="<?php echo $field['navig_url']; ?>" class="hy-nav-link" <?php echo $field['target']; ?> <?php echo $field['nofollow']; ?>><?php echo $field['navig_name']; ?></a></div>
        <?php ++$e;$k++; endforeach; endif; else: echo htmlspecialchars_decode("");endif; $field = []; ?> </div>
      <div class="index-header-search clearfix"> <?php  $tagSearchform = new \think\template\taglib\eju\TagSearchform; $_result = $tagSearchform->getSearchform("1","","","","","off"); if(is_array($_result) || $_result instanceof \think\Collection || $_result instanceof \think\Paginator): $i = 0; $e = 1;$k = 0; $__LIST__ = $_result;if( count($__LIST__)==0 ) : echo htmlspecialchars_decode("");else: foreach($__LIST__ as $key=>$field): $i= intval($key) + 1;$mod = ($i % 2 ); ?>
        <form method="get" action="<?php echo $field['action']; ?>">
          <?php echo $field['hidden']; ?>
          <input type="text" class="h_bname" placeholder="请输入查找的楼盘" name="keywords" value="<?php echo \think\Request::instance()->param('keywords'); ?>">
          <button type="submit" class="btn-search clickstat"></button>
        </form>
        <?php ++$e;$k++; endforeach;endif; else: echo htmlspecialchars_decode("");endif; $field = []; ?>
        <div class="search-list" id="newcon_ul"></div>
      </div>
      <div class="index_nav_map"> <a target="_blank" href="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("map",""); echo $__VALUE__; ?>"><i><img src="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_templets_pc"); echo $__VALUE__; ?>/skin/images/ico_map.png"/></i><span>地图找房</span></a> </div>
      <div class="index-header-right">
        <div class="index-header-control clearfix">
          <div class="hy-nav-right hy-nav-kaibo"> <a class="hy-nav-title clickstat" href="<?php  $tagGlobal = new \think\template\taglib\eju\TagGlobal; $__VALUE__ = $tagGlobal->getGlobal("web_attr_3"); echo $__VALUE__; ?>" target="_blank"> <i class="hy-nav-icon hy-nav-video-icon"></i> <span class="title">在线咨询</span> </a> </div>
        </div>
      </div>
    </div>
  </div>
</div>
 
<!-- topBar E --> 
<script>
    $(document).ready(function() {
        var isMobile = {
            Android: function() {
                return navigator.userAgent.match(/Android/i) ? true : false;
            },
            BlackBerry: function() {
                return navigator.userAgent.match(/BlackBerry/i) ? true : false;
            },
            iOS: function() {
                return navigator.userAgent.match(/iPhone|iPad|iPod/i) ? true : false;
            },
            Windows: function() {
                return navigator.userAgent.match(/IEMobile/i) ? true : false;
            },
            any: function() {
                return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Windows());
            }
        };
        if( isMobile.any() )
        {
            var path="";
            window.location.href = path;
        }
    });
</script>
<div class="ditu-main map" id="ditumain"> 
<div class="mapNav">
  <ul>
    <li <?php if(\think\Request::instance()->action() == 'index'): ?> class="hover"<?php endif; ?>><a href="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("map",""); echo $__VALUE__; ?>"><i class="img1"></i>新房</a></li>
    <li <?php if(\think\Request::instance()->action() == 'xiaoqu'): ?> class="hover"<?php endif; ?>><a href="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("mapxiaoqu",""); echo $__VALUE__; ?>"><i class="img3"></i>小区</a></li>
    <li <?php if(\think\Request::instance()->action() == 'ershou'): ?> class="hover"<?php endif; ?>><a href="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("mapershou",""); echo $__VALUE__; ?>"><i class="img4"></i>二手房</a></li>
    <li <?php if(\think\Request::instance()->action() == 'zufang'): ?> class="hover"<?php endif; ?>><a href="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("mapzufang",""); echo $__VALUE__; ?>"><i class="img5"></i>租房</a></li>
  </ul>
</div>

  <div id="jw-map" style="left: 450px;"></div>
  <div class="side-con newtop" id="conselect">
    <div class="search-box">
      <form  id="form-map">
        <div class="clearfix">
          <div class="search-inp fl" id="searchDiv" >
            <input type="text" class="txt-sty" id="keyword" name="keyword" placeholder="输入楼盘名称找房"/>
            <input type="hidden" class="txt-sty" id="orderby" name="orderby" placeholder=""/>
            <input type="hidden" class="txt-sty" id="orderway" name="orderway" placeholder=""/>
            <button class="btn-sty search-btn" id="search-map" data-url="<?php  $tagDiyurl = new \think\template\taglib\eju\TagDiyurl; $__VALUE__ = $tagDiyurl->getDiyurl("maphouselist",""); echo $__VALUE__; ?>"></button>
            <div class="search-inp-list" >
              <ul id="m_newcon_ul">
              </ul>
            </div>
          </div>
          <div class="subway-search fl pr"></div>
        </div>
        <ul class="search-type clearfix">
          <?php  $tagScreening = new \think\template\taglib\eju\TagScreening; $_result = $tagScreening->getScreening("active", "average_price,characteristic,manage_type,fitment,building_type", "", "off","1","","off","","0","off","off");if(!empty($_result["list"]) || (($_result["list"] instanceof \think\Collection || $_result["list"] instanceof \think\Paginator ) && $_result["list"]->isEmpty())): $field = $_result; if(is_array($field['list']) || $field['list'] instanceof \think\Collection || $field['list'] instanceof \think\Paginator): $i = 0; $e = 1;$k=0; $__LIST__ = $field['list'];if( count($__LIST__)==0 ) : echo htmlspecialchars_decode("");else: foreach($__LIST__ as $key=>$vo): $i= intval($key) + 1;$mod = ($i % 2 ); ?>
          <li>
            <div class=""> 
              <!--<span class="sel-text"><?php echo $vo['title']; ?></span>-->
              <select name="<?php echo $vo['name']; ?>" id="<?php echo $vo['name']; ?>" class="select_search">
                <option value=""><?php echo $vo['title']; ?></option>
                
                
                                    <?php if(is_array($vo['dfvalue']) || $vo['dfvalue'] instanceof \think\Collection || $vo['dfvalue'] instanceof \think\Paginator): $i = 0; $e = 1;$k=0; $__LIST__ = $vo['dfvalue'];if( count($__LIST__)==0 ) : echo htmlspecialchars_decode("");else: foreach($__LIST__ as $key=>$vo2): $i= intval($key) + 1;$mod = ($i % 2 ); ?>
                                    
                
                <option value="<?php echo $vo2['id']; ?>"><?php echo $vo2['name']; ?></option>
                
                
                                    <?php ++$e;$k++; endforeach; endif; else: echo htmlspecialchars_decode("");endif; $vo2 = []; ?>
                                
              
              </select>
            </div>
          </li>
          <?php ++$e;$k++; endforeach; endif; else: echo htmlspecialchars_decode("");endif; $vo = []; ?>
          <?php echo $field['hidden']; endif; $field = []; ?>
        </ul>
      </form>
    </div>
    <div class="list-box">
      <div class="list-h clearfix"> 
        <!--<span class="fl" id="bnum">为您找到<em class="green">0</em>个新盘</span>-->
        <div class="fr clearfix sort" > <?php  $TagOrderlist = new \think\template\taglib\eju\TagOrderlist; $_result = $TagOrderlist->getOrderList("active","","icon-asc","icon-desc", "average_price", "", "默认排序","1");if(!empty($_result["list"]) || (($_result["list"] instanceof \think\Collection || $_result["list"] instanceof \think\Paginator ) && $_result["list"]->isEmpty())): $field = $_result; if(is_array($field['list']) || $field['list'] instanceof \think\Collection || $field['list'] instanceof \think\Paginator): $i = 0; $e = 1;$k=0; $__LIST__ = $field['list'];if( count($__LIST__)==0 ) : echo htmlspecialchars_decode("");else: foreach($__LIST__ as $key=>$vo): $i= intval($key) + 1;$mod = ($i % 2 ); ?> <a href="javascript:;"  class="fl ml30 <?php echo $vo['currentstyle']; ?> <?php echo $vo['classstyle']; ?>" data-order="<?php echo $vo['name']; ?>" data-orderway="asc"><?php echo $vo['title']; ?> <i></i> </a> <?php ++$e;$k++; endforeach; endif; else: echo htmlspecialchars_decode("");endif; $vo = []; ?>
          <?php echo $field['hidden']; endif; $field = []; ?> </div>
      </div>
      <div class="list-con" id="right_map_content">
        <ul class="list-lou" id="right_map_ul">
        </ul>
      </div>
      <p class="list-btn" data-status="expand"></p>
    </div>
  </div>
</div>
<script type="text/javascript" src="//api.map.baidu.com/api?v=2.0&ak=<?php echo config('global.baidu_map_ak'); ?>"></script> 
<script type="text/html" id="template">
    {{# for(var i = 0, len = d.length; i < len; i++){ }}
    <li onmouseover="" onmouseout=""  onclick="openInfo('{{d[i].aid}}')">
        <a href="#"  class="clearfix" id="bid_{{d[i].aid}}">
            <div class="img">
                <img src="{{d[i].litpic}}" alt="">
                <em class="shou">{{d[i].sale_status_name}}</em>
            </div>
            <div class="text">
                <p class="mt5 clearfix">
                    <span class="name text-ellip">{{d[i].title}}</span>
					<span class="ads text-ellip">{{d[i].address}}</span>
                    <span class="unit-pri text-ellip">
                        <em class="orange fz16">{{d[i].average_price}}{{d[i].price_units}}</em>
                    </span>
                </p>
                <p class="mt15 c666">
                    {{# if(d[i].is_discount){ }}
                    <i class="tuan">惠</i>{{d[i].discount}}
                    {{# } }}
                </p>
            </div>
        </a>
    </li>
    {{# } }}
</script> 
<?php  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/js/layer.js","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/js/laytpl.js","",""); echo $__VALUE__;  $tagStatic = new \think\template\taglib\eju\TagStatic; $__VALUE__ = $tagStatic->getStatic("map/js/map_eju.js","",""); echo $__VALUE__; ?> 
<script type="text/javascript">
    $(function(){
//        $('.J_city_select').cate_select({field:'city',parent_id:'select_city',top_option:'选择区域',id:'J_city_select'});
        var lng = '<?php echo $lng; ?>';
        var lat = '<?php echo $lat; ?>';
        BMapApplication.init({'lng' : lng, 'lat' : lat, 'mapContainerId' : 'jw-map'});
        BMapApplication.requestUrl = $('#search-map').data('url');
        BMapApplication.requestParam = getParam();
        BMapApplication.getMap();
        //按条件筛选
        $('.search-btn').on('click',function(){
            search();
            return false;
        });
        //筛选
        $('.select_search').on('change',function(){
            search();
        });
        //排序
        $('.sort a').on('click',function(){
            var order = $(this).attr('data-order');
            var orderway = 'asc';
            $(this).addClass('active').siblings('.active').removeClass('active');
            $(this).siblings('.icon-desc').removeClass('icon-desc');
            $(this).siblings('.icon-asc').removeClass('icon-asc');
            if (order){
                if($(this).hasClass('icon-desc'))
                {
                    $(this).removeClass('icon-desc').addClass('icon-asc');
                    $(this).attr('data-orderway','asc');
                }else{   // if($(this).hasClass('icon-asc'))
                    $(this).removeClass('icon-asc').addClass('icon-desc');
                    $(this).attr('data-orderway','desc');
                    orderway = 'desc';
                }
            }
            $("#orderby").val(order);
            $("#orderway").val(orderway);

            search()
        });
        function search(){
            BMapApplication.viewArea = true;
            BMapApplication.requestParam = getParam();
            BMapApplication.getData();
            return false;
        }
    });
    function openInfo(aid){
        BMapApplication.makeInfoWindow(aid);
    }
    function getParam()
    {
        var result = $('#form-map').serializeArray();
        var param = {};
        $.each(result, function(i, field){
            param[field.name] = field.value;
        });
       
        return param;
    }
    $('#select_city').on('change','.J_city_select',function(){
        var city = $(this).val();
        var  url = $('#select_city').data('url');
        var param = {
            city : city
        };
        $.get(url,param,function(result){
            if(result.code == 1)
            {
                BMapApplication.requestParam.city = city;
                BMapApplication.setCenter(result.data.lng,result.data.lat,result.data.name);
                BMapApplication.getData();
            }
        });
    });
</script>
</body>
</html>